<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title></title>
    <script src="/js/jquery-3.3.1.min.js"></script>
</head>
<body>
<div>
    用户列表
</div>
</body>
<script type="application/javascript">
    $.ajax(
        {
            url:'sss',
            datatype:'json',
            method:'get',
            data:{},
            success:function(data){
                if(data.code == 200){
                    //执行正常操作
                }else if(data.code == 401){
                    location.href = 'login.html';
                }else{
                    alert(data.msg);
                }
            }

        }
    );
</script>
</html>